import request from '@/utils/request'

// 查询附件类型列表
export function listUpload(query) {
  return request({
    url: '/system/sysupload/list',
    method: 'get',
    params: query
  })
}

// 查询附件类型详细
export function getUpload(id) {
  return request({
    url: '/system/sysupload/' + id,
    method: 'get'
  })
}

// 新增附件类型
export function addUpload(data) {
  return request({
    url: '/system/sysupload',
    method: 'post',
    data: data
  })
}

// 修改附件类型
export function updateUpload(data) {
  return request({
    url: '/system/sysupload',
    method: 'put',
    data: data
  })
}

// 删除附件类型
export function delUpload(Id) {
  return request({
    url: '/system/sysupload/' + Id,
    method: 'delete'
  })
}
// 删除附件类型
export function selectUploadByCode(businessCode) {
  return request({
    url: '/system/sysupload/businessCode/' + businessCode,
    method: 'get'
  })
}
// 获取可上传文件上传大小
export function fileSize() {
  return request({
    url: '/system/sysupload/fileSize',
    method: 'get'
  })
}

